home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat3 / SCSL / scfftf.z / scfftf
Encoding:
Text File  |  2002-10-03  |  17.1 KB  |  331 lines

  1.  
  2.  
  3.  
  4. SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))                                                          SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      SSSSCCCCFFFFFFFFTTTTFFFF, SSSSCCCCFFFFFFFFTTTTMMMMFFFF, SSSSCCCCFFFFFFFFTTTT2222DDDDFFFF, SSSSCCCCFFFFFFFFTTTT3333DDDDFFFF, DDDDZZZZFFFFFFFFTTTTFFFF, DDDDZZZZFFFFFFFFTTTTMMMMFFFF, DDDDZZZZFFFFFFFFTTTT2222DDDDFFFF, DDDDZZZZFFFFFFFFTTTT3333DDDDFFFF
  10.      - Deallocate memory tacked on to the table array during initialization
  11.  
  12. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  13.      Single precision complex -> Single precision complex
  14.  
  15.           Fortran:
  16.                _i_s_t_a_t_u_s ==== SSSSCCCCFFFFFFFFTTTTFFFF ((((_n,,,, _t_a_b_l_e))))
  17.                _i_s_t_a_t_u_s ==== SSSSCCCCFFFFFFFFTTTTMMMMFFFF ((((_n,,,, _t_a_b_l_e))))
  18.                _i_s_t_a_t_u_s ==== SSSSCCCCFFFFFFFFTTTT2222DDDDFFFF ((((_n_1,,,, _n_2,,,, _t_a_b_l_e))))
  19.                _i_s_t_a_t_u_s ==== SSSSCCCCFFFFFFFFTTTT3333DDDDFFFF ((((_n_1,,,, _n_2,,,, _n_3,,,, _t_a_b_l_e))))
  20.  
  21.           C/C++:
  22.                ####iiiinnnncccclllluuuuddddeeee <<<<ssssccccssssllll____fffffffftttt....hhhh>>>>
  23.                _i_s_t_a_t_u_s ==== ssssccccffffffffttttffff ((((iiiinnnntttt _n,,,, ffffllllooooaaaatttt *_t_a_b_l_e))));;;;
  24.                _i_s_t_a_t_u_s ==== ssssccccffffffffttttmmmmffff ((((iiiinnnntttt _n,,,, ffffllllooooaaaatttt *_t_a_b_l_e))));;;;
  25.                _i_s_t_a_t_u_s ==== ssssccccfffffffftttt2222ddddffff ((((iiiinnnntttt _n_1,,,, iiiinnnntttt _n_2,,,, ffffllllooooaaaatttt *_t_a_b_l_e))));;;;
  26.                _i_s_t_a_t_u_s ==== ssssccccfffffffftttt3333ddddffff ((((iiiinnnntttt _n_1,,,, iiiinnnntttt _n_2,,,, iiiinnnntttt _n_3,,,, ffffllllooooaaaatttt *_t_a_b_l_e))));;;;
  27.  
  28.      Double precision complex -> Double precision complex
  29.  
  30.           Fortran:
  31.                _i_s_t_a_t_u_s ==== DDDDZZZZFFFFFFFFTTTTFFFF ((((_n,,,, _t_a_b_l_e))))
  32.                _i_s_t_a_t_u_s ==== DDDDZZZZFFFFFFFFTTTTMMMMFFFF ((((_n,,,, _t_a_b_l_e))))
  33.                _i_s_t_a_t_u_s ==== DDDDZZZZFFFFFFFFTTTT2222DDDDFFFF ((((_n_1,,,, _n_2,,,, _t_a_b_l_e))))
  34.                _i_s_t_a_t_u_s ==== DDDDZZZZFFFFFFFFTTTT3333DDDDFFFF ((((_n_1,,,, _n_2,,,, _n_3,,,, _t_a_b_l_e))))
  35.  
  36.           C/C++:
  37.                ####iiiinnnncccclllluuuuddddeeee <<<<ssssccccssssllll____fffffffftttt....hhhh>>>>
  38.                _i_s_t_a_t_u_s ==== ddddzzzzffffffffttttffff ((((iiiinnnntttt _n,,,, ddddoooouuuubbbblllleeee *_t_a_b_l_e))));;;;
  39.                _i_s_t_a_t_u_s ==== ddddzzzzffffffffttttmmmmffff ((((iiiinnnntttt _n,,,, ddddoooouuuubbbblllleeee *_t_a_b_l_e))));;;;
  40.                _i_s_t_a_t_u_s ==== ddddzzzzfffffffftttt2222ddddffff ((((iiiinnnntttt _n_1,,,, iiiinnnntttt _n_2,,,, ddddoooouuuubbbblllleeee *_t_a_b_l_e))));;;;
  41.                _i_s_t_a_t_u_s ==== ddddzzzzfffffffftttt3333ddddffff ((((iiiinnnntttt _n_1,,,, iiiinnnntttt _n_2,,,, iiiinnnntttt _n_3,,,, ddddoooouuuubbbblllleeee *_t_a_b_l_e))));;;;
  42.  
  43. IIIIMMMMPPPPLLLLEEEEMMMMEEEENNNNTTTTAAAATTTTIIIIOOOONNNN
  44.      These routines are part of the SCSL Scientific Library and can be loaded
  45.      using either the ----llllssssccccssss or the ----llllssssccccssss____mmmmpppp option.  The ----llllssssccccssss____mmmmpppp option
  46.      directs the linker to use the multi-processor version of the library.
  47.  
  48.      When linking to SCSL with ----llllssssccccssss or ----llllssssccccssss____mmmmpppp, the default integer size is
  49.      4 bytes (32 bits). Another version of SCSL is available in which integers
  50.      are 8 bytes (64 bits).  This version allows the user access to larger
  51.      memory sizes and helps when porting legacy Cray codes.  It can be loaded
  52.      by using the ----llllssssccccssss____iiii8888 option or the ----llllssssccccssss____iiii8888____mmmmpppp option. A program may use
  53.      only one of the two versions; 4-byte integer and 8-byte integer library
  54.      calls cannot be mixed.
  55.  
  56.      The C and C++ prototypes shown above are appropriate for the 4-byte
  57.      integer version of SCSL. When using the 8-byte integer version, the
  58.      variables of type iiiinnnntttt become lllloooonnnngggg lllloooonnnngggg and the <<<<ssssccccssssllll____fffffffftttt____iiii8888....hhhh>>>> header
  59.      file should be included.
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))                                                          SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))
  71.  
  72.  
  73.  
  74. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  75.      These routines deallocate memory added on to the _t_a_b_l_e array during
  76.      initialization if the first element of the _i_s_y_s array was set to 0 in the
  77.      call to SSSSCCCCFFFFFFFFTTTT(3S), SSSSCCCCFFFFFFFFTTTTMMMM(3S), SSSSCCCCFFFFFFFFTTTT2222DDDD((((3333SSSS)))), SSSSCCCCFFFFFFFFTTTT3333DDDD((((3333SSSS)))),,,, DDDDZZZZFFFFFFFFTTTT(3S),
  78.      DDDDZZZZFFFFFFFFTTTTMMMM(3S), DDDDZZZZFFFFFFFFTTTT2222DDDD(3S) or DDDDZZZZFFFFFFFFTTTT3333DDDD(3S).  If the appropriate one of these
  79.      deallocation routines is not used, that memory will leak, and repeated
  80.      initializations using the same table array can exhaust memory.  If the
  81.      first element of the _i_s_y_s array was set to 1 in the call to SSSSCCCCCCCCFFFFFFFFTTTT(3S),
  82.      etc. (and this is the recommended value), there is no potential memory
  83.      leak and these routines do not need to be called. If they are called,
  84.      they will simply return 0.
  85.  
  86.      See the NOTES section of this man page for information about the
  87.      interpretation of the data types described in the following arguments.
  88.  
  89.      These routines have the following arguments:
  90.  
  91.      _i_s_t_a_t_u_s   Integer (result status). (output)
  92.                0 indicates the memory was successfully freed.  Non-zero
  93.                indicates that the memory was not freed because the transform
  94.                size did not match the supplied table array.
  95.  
  96.      _n         Integer.  (input)
  97.                Size of the one dimensional transform (the number of values in
  98.                the input array used to initialize table).  _n >= 0.
  99.  
  100.      _n_1        Integer.   (input)
  101.                Transform size in the first dimension.
  102.  
  103.      _n_2        Integer.   (input)
  104.                Transform size in the second dimension.
  105.  
  106.      _n_3        Integer.   (input)
  107.                Transform size in the third dimension.
  108.  
  109.      _t_a_b_l_e     Array of the following dimensions. (input)
  110.                SSSSCCCCFFFFFFFFTTTTFFFF: Single precision array of dimension (_n + _N_F_R).
  111.                DDDDZZZZFFFFFFFFTTTTFFFF: Double precision array of dimension (_n + _N_F_R).
  112.                SSSSCCCCFFFFFFFFTTTTMMMMFFFF: Single precision array of dimension (_n + _N_F_R).
  113.                DDDDZZZZFFFFFFFFTTTTMMMMFFFF: Double precision array of dimension (_n + _N_F_R).
  114.                SSSSCCCCFFFFFFFFTTTT2222DDDDFFFF: Single precision array of dimension (_n_1 + _N_F_R) +
  115.                (2*_n_2 + _N_F).
  116.                DDDDZZZZFFFFFFFFTTTT2222DDDDFFFF: Double precision array of dimension (_n_1 + _N_F_R) +
  117.                (2*_n_2 + _N_F).
  118.                SSSSCCCCFFFFFFFFTTTT3333DDDDFFFF: Single precision array of dimension (_n_1 + _N_F_R) +
  119.                (2*_n_2 + _N_F) + (2*_n_3 + _N_F).
  120.                DDDDZZZZFFFFFFFFTTTT3333DDDDFFFF: Double precision array of dimension (_n_1 + _N_F) + (2*_n_2
  121.                + _N_F) + (2*_n_3 + _N_F).
  122.                Table of factors and roots of unity initialized by a call to
  123.                the corresponding routine (SSSSCCCCFFFFFFFFTTTT, SSSSCCCCFFFFFFFFTTTTMMMM, SSSSCCCCFFFFFFFFTTTT2222DDDD, SSSSCCCCFFFFFFFFTTTT3333DDDD,
  124.                DDDDZZZZFFFFFFFFTTTT, DDDDZZZZFFFFFFFFTTTTMMMM, DDDDZZZZFFFFFFFFTTTT2222DDDD, DDDDZZZZFFFFFFFFTTTT3333DDDD).  _N_F = 30 and _N_F_R====11115555 if table
  125.                was initialized using _i_s_y_s((((0000))))=0.  _N_F====_N_F_R====256 if _t_a_b_l_e was
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))                                                          SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))
  137.  
  138.  
  139.  
  140.                initialized using _i_s_y_s((((0000))))=1.
  141.  
  142. NNNNOOOOTTTTEEEESSSS
  143.      The following data types are described in this documentation:
  144.  
  145.           TTTTeeeerrrrmmmm UUUUsssseeeedddd                     DDDDaaaattttaaaa ttttyyyyppppeeee
  146.  
  147.      Fortran:
  148.  
  149.           Array dimensioned 0000........_n----1111      XXXX((((0000::::nnnn----1111))))
  150.  
  151.           Array of dimensions (_m,_n)     XXXX((((mmmm,,,,nnnn))))
  152.  
  153.           Array of dimensions (_m,_n,_p)   XXXX((((mmmm,,,,nnnn,,,,pppp))))
  154.  
  155.           Integer                       IIIINNNNTTTTEEEEGGGGEEEERRRR (IIIINNNNTTTTEEEEGGGGEEEERRRR****8888 for ----llllssssccccssss____iiii8888[[[[____mmmmpppp]]]])
  156.  
  157.           Single precision              RRRREEEEAAAALLLL
  158.  
  159.           Double precision              DDDDOOOOUUUUBBBBLLLLEEEE PPPPRRRREEEECCCCIIIISSSSIIIIOOOONNNN
  160.  
  161.           Single precision complex      CCCCOOOOMMMMPPPPLLLLEEEEXXXX
  162.  
  163.           Double precision complex      DDDDOOOOUUUUBBBBLLLLEEEE CCCCOOOOMMMMPPPPLLLLEEEEXXXX
  164.  
  165.      C/C++:
  166.  
  167.           Array dimensioned 0000........_n----1111      xxxx[[[[_n]]]]
  168.  
  169.           Array of dimensions (_m,_n)     xxxx[[[[mmmm****nnnn]]]] oooorrrr xxxx[[[[nnnn]]]][[[[mmmm]]]]
  170.  
  171.           Array of dimensions (_m,_n,_p)   xxxx[[[[mmmm****nnnn****pppp]]]] oooorrrr xxxx[[[[pppp]]]][[[[nnnn]]]][[[[mmmm]]]]
  172.  
  173.           Integer                       iiiinnnntttt (lllloooonnnngggg lllloooonnnngggg for ----llllssssccccssss____iiii8888[[[[____mmmmpppp]]]])
  174.  
  175.           Single precision              ffffllllooooaaaatttt
  176.  
  177.           Double precision              ddddoooouuuubbbblllleeee
  178.  
  179.           Single precision complex      ssssccccssssllll____ccccoooommmmpppplllleeeexxxx
  180.  
  181.           Double precision complex      ssssccccssssllll____zzzzoooommmmpppplllleeeexxxx
  182.  
  183.      C++ STL:
  184.  
  185.           Array dimensioned 0000........_n----1111      xxxx[[[[_n]]]]
  186.  
  187.           Array of dimensions (_m,_n)     xxxx[[[[mmmm****nnnn]]]] oooorrrr xxxx[[[[nnnn]]]][[[[mmmm]]]]
  188.  
  189.           Array of dimensions (_m,_n,_p)   xxxx[[[[mmmm****nnnn****pppp]]]] oooorrrr xxxx[[[[pppp]]]][[[[nnnn]]]][[[[mmmm]]]]
  190.  
  191.  
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))                                                          SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))
  203.  
  204.  
  205.  
  206.           Integer                       iiiinnnntttt (lllloooonnnngggg lllloooonnnngggg for ----llllssssccccssss____iiii8888[[[[____mmmmpppp]]]])
  207.  
  208.           Single precision              ffffllllooooaaaatttt
  209.  
  210.           Double precision              ddddoooouuuubbbblllleeee
  211.  
  212.           Single precision complex      ccccoooommmmpppplllleeeexxxx<<<<ffffllllooooaaaatttt>>>>
  213.  
  214.           Double precision complex      ccccoooommmmpppplllleeeexxxx<<<<ddddoooouuuubbbblllleeee>>>>
  215.  
  216. EEEEXXXXAAAAMMMMPPPPLLLLEEEESSSS
  217.      Initialize the complex array table in preparation for doing an FFT of
  218.      size 1024. Take the FFT of _x and store the results in _y. Deallocate extra
  219.      memory tagged on to the table array.
  220.  
  221.           Fortran:
  222.  
  223.                !This example uses isys(0) = 0. The recommended value
  224.                !    for current versions of SCSL is isys(0) = 1 which,
  225.                !    if used, will eliminate the need to call SCFFTF.
  226.                !
  227.                REAL X(0:1023)
  228.                COMPLEX Y(0:1024)
  229.                REAL TABLE(1024 + 15)  ! +15 too small for isys(0) = 1
  230.                REAL WORK(1024)
  231.                INTEGER ISYS(0:0)
  232.                INTEGER ISTATUS, CCFFTF
  233.                ISYS(0) = 0
  234.                CALL SCFFT(0, 1024, 0.0, DUMMY, DUMMY, TABLE, DUMMY, 0)
  235.                CALL SCFFT(1, 1024, 1.0, X, Y, TABLE, WORK, 0)
  236.                ISTATUS = SCFFTF(1024, TABLE)
  237.  
  238.  
  239.           C/C++:
  240.  
  241.           /* This example uses isys[0] = 0. The recommended value
  242.            * for current versions of SCSL is isys[0] = 1 which,
  243.            * if used, will eliminate the need to call scfftf().
  244.            */
  245.           #include <scsl_fft.h>
  246.           float x[1024];
  247.           scsl_complex y[1025];
  248.           float table[1024 + 15];  /* +15 too small for isys[0] = 1 */
  249.           float work[1024];
  250.           int isys[1];
  251.           int istatus;
  252.           isys[0] = 0;
  253.           scfft(0, 1024, 0.0f, NULL, NULL, table, NULL, isys);
  254.           scfft(1, 1024, 1.0f, X, Y, table, work, isys);
  255.           istatus = scfftf(1024, table);
  256.  
  257.  
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))                                                          SSSSCCCCFFFFFFFFTTTTFFFF((((3333SSSS))))
  269.  
  270.  
  271.  
  272.           C++ STL:
  273.  
  274.           // This example uses isys[0] = 0. The recommended value
  275.           // for current versions of SCSL is isys[0] = 1 which,
  276.           // if used, will eliminate the need to call scfftf().
  277.           //
  278.           #include <complex.h>
  279.           #include <scsl_fft.h>
  280.           float x[1024];
  281.           complex<float> y[1025];
  282.           float table[1024 + 15];  /* +15 too small for isys[0] = 1 */
  283.           float work[2*1024];
  284.           int isys[1];
  285.           int istatus;
  286.           isys[0] = 0;
  287.           scfft(0, 1024, 0.0f, NULL, NULL, table, NULL, isys);
  288.           scfft(1, 1024, 1.0f, X, Y, table, work, isys);
  289.           istatus = scfftf(1024, table);
  290.  
  291.  
  292. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  293.      IIIINNNNTTTTRRRROOOO____FFFFFFFFTTTT(3S), IIIINNNNTTTTRRRROOOO____SSSSCCCCSSSSLLLL(3S)
  294.  
  295.  
  296.  
  297.  
  298.  
  299.  
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.                                                                         PPPPaaaaggggeeee 5555
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.